home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1996 May / EnigmA AMIGA RUN 07 (1996)(G.R. Edizioni)(IT)[!][issue 1996-05][EARSAN CD VI].iso / progs / utilmisc / dansmazes / dansmazes.txt < prev    next >
Text File  |  1995-04-04  |  8KB  |  206 lines

  1. DansMazes v1.13, written by Daniel Pink in BlitzBasic ][
  2.  
  3. This prog is MailWare.  No money expected.  Yes, its FREE!
  4.  
  5.  
  6. Requirements
  7. ============
  8.   Needs an Amiga,  running OS 2.04 or above,  the Reqtools.library and the
  9.   Gadtools.library in you Libs: directory.  See discussion on memory usage
  10.   for memory requirements.
  11.  
  12. Description
  13. ===========
  14.   Dans mazes allows mazes to be created up  to  a size of 1000x1000, memory
  15.   permitting.  The mazes created have only one route through, and all parts
  16.   of the maze should  be  accessible.  It also allows mazes to be saved and
  17.   loaded, and viewed in a 2D  and  a  3D format.  These five options can be
  18.   accessed via the buttons in the main window, each of which has a hot key.
  19.  
  20. Buttons
  21. =======
  22. Create New Maze Button
  23.  
  24.   This is the function that DansMazes is based around.  Just enter values for
  25.   the width and height, and a maze will be generated  to  those requirements.
  26.   As larger mazes take longer to produce,  there is an option of  a  progress
  27.   indicator.  See Config section later for details.
  28.  
  29. Save Current Maze Button
  30.  
  31.   This allows a maze to be saved to disk.  First a file requester prompts for
  32.   a file name,  and then there is  an  option to save in a packed or unpacked
  33.   format.   The unpacked format takes  ((NoColumns+2)*(NoRows+1))+8 bytes for
  34.   the maze,  while  the  packed format  takes  ((NoColumns+2)*(NoRows+1)/4)+8
  35.   bytes. I.E.  A 100 by 100 maze will use 10310 bytes in the unpacked format,
  36.   and 2583 bytes in the packed format.   The packing and unpacking process is
  37.   so fast  on  my  A1200 @28 Mhz  that  the  time taken to pack and unpack is
  38.   hardly noticeable!
  39.  
  40. Load New Maze Button
  41.  
  42.   This  allows  a  previously saved maze  to be reloaded.   A file requester
  43.   prompts for a file name, and then the maze is loaded.  Packed and unpacked
  44.   formats are automatically recognised.
  45.  
  46. View Maze (2D) Button
  47.  
  48.   This allows a maze to be viewed in 2D.  First the maze is drawn to a bitmap,
  49.   and then a window opens to allow the bitmap to be viewed.  The maze is drawn
  50.   using the number  of  pixels per square specified  in  the config.  As large
  51.   mazes take a while to draw there is an option of a progress indicator.   See
  52.   Config section for details.
  53.  
  54. View Maze (3D) Button
  55.  
  56.   This opens a window and shows a 3D view of the maze, facing south from the
  57.   start position.   The  maze  can then  be explored using a joystick in the
  58.   joystick port, or the cursor keys.   The direction faced can be altered by
  59.   pushing left or right, and backwards and forwards allows a single step, if
  60.   the way is not blocked!   The view can  be altered via the menu for the 3D
  61.   window.
  62.  
  63. Menus
  64. =====
  65. Main Menu
  66.  
  67.   The About option brings up an about requester, which also gives details
  68.   about the size and memory usage of the current maze.
  69.  
  70.   The Save Config option saves the current config information to the programs
  71.   icon file.
  72.  
  73.   The Indicator Rate option allows the rate at which the indicator is updated
  74.   to be altered.   The figure specifies the amount of time between updates in
  75.   ticks.  (1/50th second for PAL, 1/60th second for NTSC)
  76.  
  77.   The 2D Pixel option allows the amount of pixels used by the 2D drawing
  78.   routine to be altered.
  79.  
  80.   The Quit option.  Well, who would want to anyway :)
  81.  
  82.  
  83. 2D Maze Menu
  84.  
  85.   The Save Bitmap option allows the 2D bitmap to be saved to disk in IFF format.
  86.  
  87.   The Close Window option closes the 2D Maze window.
  88.  
  89.  
  90. 3D Maze Menu
  91.  
  92.   The Close Window option closes the 3D Maze window.
  93.  
  94.   The Inside View option alters the 3D view to inside the maze.
  95.  
  96.   The Above View option alters the 3D view to slightly above the maze.
  97.  
  98.  
  99. Keyboard Shortcuts.
  100. ===================
  101.   All of the menus have keyboard shortcuts, all requesters can be operated via
  102.   the  keyboard,  the buttons  in  the  main  window can  be  accessed via the
  103.   keyboard, movement about the  3D  maze uses the keyboard, the 2D maze can be
  104.   scrolled with the cursor keys, and the active window can be altered with the
  105.   TAB key.
  106.  
  107.  
  108. Config
  109. ======
  110.   Configuration  information  is  stored in the icon file.   This can also be
  111.   written  to  using  the  option  in  the main window.  If no information is
  112.   present or it is invalid then default values are used.  Config items are as
  113.   follows :-
  114.  
  115. MAINWIDTH=xxx
  116.   specifies the width of the main window in pixels.
  117.  
  118. MAINHEIGHT=xxx
  119.   specifies the height of the main window in pixels.
  120.  
  121. MAINX=xxx
  122.   specifies the X position of the top left of the main window in pixels.
  123.  
  124. MAINY=xxx
  125.   specifies the Y position of the top left of the main window in pixels.
  126.  
  127. 3DVIEW=ABOVE|INSIDE
  128.   specifies which view to use by default for the 3D window.  Only use ONE of
  129.   the values!
  130.  
  131. 2DPIXACROSS=xx
  132.   specifies the number of pixels to use across for each square.
  133.  
  134. 2DPIXDOWN=xx
  135.   specifies the number of pixels to use down for each square.
  136.  
  137. INDICATORRATE=xx
  138.   specifies the rate to update the progress indicator.  (10..60 ticks)
  139.  
  140. MAZELARGE=xxx
  141.   specifies the size in area of the maze at which to use a progress indicator.
  142.   This allows the progress indicator to be used when the maze will take a long
  143.   time  to  be  processed,  which  will  obviously be different  for different
  144.   machine specs.
  145.  
  146.  
  147. Memory usage
  148. ============
  149.   For large mazes the memory usage  can  be  quite intensive.   If you try to
  150.   create a maze which is too large,  or draw a maze which is too large,  then
  151.   the program won't guru, but should exit cleanly,  returning ALL memory that
  152.   was in use.  The current memory usage can be viewed in the About requester.
  153.  
  154.   A 1000x1000 maze would use 1000*1000 bytes (976.6 K) of fast ram if
  155.   available, or chip ram otherwise.
  156.  
  157.   A 1000x1000 maze with 4 pixels across and down per square would need 1953K
  158.   of CHIP ram for the 2D bitmap.
  159.  
  160.   The 3D bitmap used is not dependent on the maze size, but the size of your
  161.   screen.
  162.  
  163.   Mazes can be created to a  larger  size  than  1000x1000, this was just a
  164.   figure  I  decided upon  that  seems  much  larger than is needed, unless
  165.   you're really sad I doubt you could really be bothered to complete a maze
  166.   that big!   The only reason for  creating a maze that big is to show that
  167.   it can be done.
  168.  
  169.  
  170.   If you're having problems getting it to work, want to express an opinion on
  171.   the prog, have any suggestions for improvements, you want a copy of the BB2
  172.   source code or you're just a bit bored, then email me.  Also if you want to
  173.   use it to generate mazes for a game, let me know and I'll  explain the file
  174.   format.  Also, if you could let me know the config of your machine, as this
  175.   program has only been tested on my 3.0 Dos A1200,  and I would like to know
  176.   if it works on  different  dos  versions.  In theory it should work on 2.0,
  177.   but I haven't been able check this yet.
  178.  
  179. .------------------------.
  180. |     --.                |
  181. |     |  \ ,--, ,--,     |
  182. |     |  | |  | |  |     |
  183. |     ---' `--`-`  '     |
  184. |========================|
  185. | D.C.J.Pink@Herts.ac.uk |
  186. |   (until ~July 1995)   |
  187. `------------------------'
  188.  
  189. Thanks to
  190.  
  191. Acid software for the excellent BlitzBasic ][. (If you haven't got it, then
  192. BUY it NOW, its worth every penny/cent/etc!)
  193.  
  194. LES (Leading Edge Software) for their update to the BlitzBasic Debugger, and
  195. many new Blitz commands.
  196.  
  197. Neil O'Rourke for his Blitz commands for the progress indicator, and
  198. for access to the ReqTools lib.
  199.  
  200. History
  201. =======
  202. V1.14  Bug fix.  Visited Mr Guru if a maze not requiring the progress
  203.        indicator was created after one that did require the progress
  204.        indicator.
  205. V1.13  First release on aminet
  206.